<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Ajax</title>
    <script src="jquery.min.js"></script>
</head>
<body>

<button id="load" style="width: 100%; height: 30px;">加载</button>
<div id="photos"></div>

<script>
    $(() => {
        const url = 'http://api.tianapi.com/meinv/index?key=962cf8668c6023bfa93da969bea239b7&page='
        let page = 0
        $('#load').on('click', (evt) => {
            page += 1
            $.getJSON(url + page, (json) => {
                json.newslist.forEach((mm) => {
                    $('#photos').prepend($('<img>').attr('src', mm.picUrl).attr('with', '150px').attr('height', '200px'))
                })
            })

        })
    })
</script>
</body>











































































































































































































































































</html>